<script id="list-tpl" type="text/html"
        data-params='{"url":"/education/admin/marquee","dataName":"marqueeData","pageid":"#page", "method":"post"}'>
    <table id="example" class="layui-table lay-even" data-name="marqueeData" data-tplid="list-tpl">
        <thead>
            <tr>
                <th width="30"><input type="checkbox" id="checkall" data-name="checkbox" lay-filter="check"
                                      lay-skin="primary"></th>
                <th width="350">标题</th>
                <th>封面图</th>
                <th>网页地址</th>
                <th width="170">创建时间</th>
                <th width="200">操作</th>
            </tr>
        </thead>
        <tbody>
            {{# layui.each(d.list, function(index, item){ }}
            <tr>
                <td><input type="checkbox" name="checkbox" value="{{ item.id}}" lay-skin="primary"></td>
                <td>
                    {{# if(item.title == null){ }} {{#  } else { }} {{ item.title}}  {{#  } }}
                </td>
                <td>
                    <img src="/education{{ item.image }}" alt="..." class="img-thumbnail">
                </td>
                <td>
                    <a target="_blank" href="{{ item.html_url || ''}}" >{{ item.html_url || ''}}</a>
                </td>

                <td>{{# if(item.create_time == null){ }} {{#  } else { }} {{ item.create_time}}  {{#  } }}</td>
                <td>
                    <button class="layui-btn layui-btn-mini modal-catch"
                            data-params='{"content": ".edit-subcat","area":"600px,400px","title":"编辑","key":"id={{ item.id }}","type":"1"}'>
                        <i class="iconfont">&#xe653;</i>更换图片
                    </button>
                </td>

            </tr>
            {{# }); }}
        </tbody>

    </table>
</script>